# name : obf spending function
# key : spend_obf
# contributor: Shuguang Sun
# --
spend_obf <- function(t, alpha = 0.025, sided = 1) {
  2 * sided * pnorm(
    qnorm(alpha / (2 * sided), lower.tail = FALSE) / sqrt(t),
    lower.tail = FALSE
  )
}
